<template>
  <template v-if="route.path.startsWith('/user')">
    <!-- <UserLayout/> -->
     <router-view></router-view>
  </template>

  <template v-else>
    <BasicLayout/>
  </template>
</template>
   

<script setup lang="ts">
import BasicLayout from '@/layouts/BasicLayout.vue'
import UserLayout from '@/layouts/UserLayout.vue'
import { getLoginUserUsingGet } from '@/api/userController'
import { useRoute } from 'vue-router'
import { onMounted } from 'vue';

const route = useRoute()

// 全局初始化函数,全局单次调用代码
const doInit = () => {
  console.log('hello,欢迎来到我的项目')
}

onMounted(() => {
  doInit()
})
</script>



<style scoped>

</style>
